/*
 * File:    RenderContext.java
 * Created: 09-Feb-2009
 * Version: $Id$
 *
 * COPYRIGHT (C) 2009, Bitgate Mobile, LLC.  All Rights Reserved.
 *
 * software@bitgatemobile.com
 */

package com.webplasm.context;

import com.bitgate.util.service.protocol.http.HttpClientContext;
import com.webplasm.render.tags.u.procedure.LocalProcedureStore;
import com.webplasm.store.VariableStore;

/**
 * This class is used to store information about a currently processing render in the Webplasm system.  It contains
 * information such as variable information, procedures that have been loaded and registered, output context types, and
 * so on.
 * 
 * @author kenji
 * @since Webplasm 2.0
 */
public class RenderContext {
	private VariableStore variableStore;
	private HttpClientContext httpClientContext;
	private LocalProcedureStore localProcedureStore;
	private String contentType;
	
	public RenderContext(HttpClientContext httpClientContext) {
		this.variableStore = new VariableStore();
		this.localProcedureStore = new LocalProcedureStore();
		this.httpClientContext = httpClientContext;
		this.contentType = "text/html";
	}
	
	public void setContentType(String contentType) {
		this.contentType = contentType;
	}
	
	public VariableStore getVariableStore() {
		return variableStore;
	}
	
	public HttpClientContext getClientContext() {
		return httpClientContext;
	}
	
	public LocalProcedureStore getLocalProcedureStore() {
		return localProcedureStore;
	}
	
	public String getContentType() {
		return contentType;
	}
}